package mtest.structure;

public class Demo8 {
    public static void main(String[] args) {
        //练习用while for 循环输出 1-1000 之间能被5整除的数，并且每行输出3个
        for (int i = 0; i <= 1000; i++) {
            if (i % 5 == 0) {
                System.out.print(i + "\t");
            }
            if (i % (5 * 3) == 0) {
                System.out.println();// 输出完会换行
                // System.out.print("\n");  输出完不会换行
            }

        }
        System.out.println("****************");

        // 九九乘法表
        for (int j = 1; j <= 9; j++) {
            for (int i = 1; i <= j; i++) {
                System.out.print(i + "*" + j + "=" + (j * i) + "\t");
            }
            System.out.println();
        }


    }
}
